{$form->getElement('application')->render()}
{$form->getElement('controller')->render()}
{$form->getElement('method')->render()}
{$form->getElement('tarefa[version]')->render()}
{$form->getElement('tarefa[id_tarefa]')->render()}
<div class="control-group">
	{$form->getElement('tarefa[dt_prazo]')->getLabel()->render()}
	<div class="controls">
		{$form->getElement('tarefa[dt_prazo]')->render()}
	</div>
</div>
<div class="control-group">
	{$form->getElement('tarefa[equipe]')->getLabel()->render()}
	<div class="controls">
		{$form->getElement('tarefa[equipe]')->render()}
	</div>
</div>
<div class="control-group">
	{$form->getElement('tarefa[responsavel]')->getLabel()->render()}
	<div class="controls">
		{$form->getElement('tarefa[responsavel]')->render()}
	</div>
</div>
<div id="myModalHeader">
	<h3>Atribuir Tarefa #{$tarefa->getIdTarefa()}</h3>
</div>
<div id="myModalFooter">
	{$form->getElement('salvar')->render()}
</div>
{literal}
<script type="text/javascript">
	$(document).ready(function() {
		initModal();
		initDatePicker('.datepicker');
		
		var combo	= $('#id_tarefa_responsavel');
		$('#id_tarefa_equipe').change(function(){
			$.getJSON(BASE_PATH+'intelihelp/equipe/returnMembros/id/'+this.value)
			.success(function(data){
				$("#id_tarefa_responsavel option").remove();
				combo.append($("<option />").val(null).text('-- Selecione --'));
				
				$.each(data.idresponsavel, function(key,value) {
					combo.append($("<option />").val(key).text(value));
				});
			});
		});
	})
</script>
{/literal}